{template 'public/header'}
{template 'public/comhead'}
<link rel="stylesheet" type="text/css" href="../addons/zh_gjhdbm/template/public/ygcsslist.css">
<style type="text/css">
  .storespan2{font-size: 14px;color: white;margin: 5px;position: relative;background-color: #44abf7;}
    .storespan2:hover{color: #fff;}
    .storespan2:hover .bianji{display: block;}
    .rcbox{font-size: 14px;padding-top: 5px;padding-bottom: 5px;height: 44px;}
    .rcinput{width: 300px;height: 30px;border:1px solid #666;text-indent: 1em;}
    .rczuo,.rczuo2{display: none;position: absolute;z-index: 10;}
</style>
<ul class="nav nav-tabs">
  <span class="ygxian"></span>
    <div class="ygdangq">当前位置:</div>
   <li class="active"><a href="{php echo $this->createWebUrl('type')}">分类管理</a></li>
    <li><a href="{php echo $this->createWebUrl('addtype')}">添加分类</a></li>
</ul>
</ul>

  <div class="row ygrow">
      <div class="col-lg-12">
       
   
      </div>    
  </div>
<div class="main">
    <div class="panel panel-default">
      <div class="panel-heading">全部分类</div>
        <div class="table-responsive">
          <table class="col-md-12">
              <tr class="yg5_tr1">
                <th class="store_td1 col-md-1">顺序</th>
                <th class="col-md-1">分类id</th>
                <th class="col-md-1">分类名称</th>
                <th class="col-md-1">状态</th>
               
                  <th class="col-md-2">操作</th>
              </tr>
              {loop $list $key $item}
              <tr class="yg5_tr2">
                <td>
                {$item['num']}
                </td>
              	<td>
                	{$item['id']}
                </td>
           <!--      <td>
                <img class="store_list_img" src="{media  $item['img']}" alt=""/>
                </td>    -->
                <td >
                {$item['type_name']}
                </td> 
              
               <td>{if $item['state']==1} <span class="label storeblue">  <a href="{php echo $this->createWebUrl('type', array('id' => $item['id'],'op'=>change,'state'=>2))}"   >启用</a></span>{elseif $item['state']==2} <span class="label storegrey"><a href="{php echo $this->createWebUrl('type', array('id' => $item['id'],'op'=>change,'state'=>1))}">禁用</a></span>{/if}</td>
               
                 <td>
                 <a href="{php echo $this->createWebUrl('addtype',array('id'=>$item['id']));}" class="storespan btn btn-xs">
                      <span class="fa fa-pencil"></span>
                      <span class="bianji">编辑
                          <span class="arrowdown"></span>
                      </span>                            
                  </a>
                  <a class="storespan btn btn-xs" href="{php echo $this->createWebUrl('type', array('id'=>$item['id'],'op'=>'delete'))}" onclick="return confirm('确认删除吗？');return false;">
                      <span class="fa fa-trash-o"></span>
                      <span class="bianji">删除
                          <span class="arrowdown"></span>
                      </span>
                  </a>
                 <!-- <a href="{php echo $this->createWebUrl('orderinfo',array('id'=>$item['id']));}"><button class="btn btn-success btn-xs">查看</button></a>
                <a class="btn btn-danger btn-xs" href="{php echo $this->createWebUrl('zcorder', array('id'=>$item['id'],'op'=>'delete'))}" onclick="return confirm('确认删除吗？');return false;" title="删除">删</a> -->
                
                </td>
               <!--  <td> {$pager}</td> -->
              </tr>
              {/loop}
             
                {if empty($list)}
               <tr>
                  <td colspan="4" style="padding: 10px 30px;">
                    暂无订单信息
                  </td>
                </tr>
             
              {/if}
          </table>
        </div>
    </div>
</div>
<div class="text-right we7-margin-top">{$pager}</div>
<script type="text/javascript">
    $(function(){
        $("#frame-6").show();
        $("#yframe-6").addClass("wyactive");
    })
</script>